package basic.io;

import java.io.*;
import java.util.Arrays;

//����ʵ��һ������һ���ַ�������������д����һ���ı��ļ�
public class StringSort {
   public static void main(String[] args) throws IOException {
	 BufferedReader bis = new BufferedReader(new FileReader("f.txt"));
	 String line = bis.readLine();
	 System.out.println(line);
	 bis.close();
	 char[] chars = line.toCharArray();
	 Arrays.sort(chars);
	 String string = new String(chars);
	 System.out.println(string);
	 BufferedWriter bWriter = new BufferedWriter(new FileWriter("ff.txt"));
	 bWriter.write(string);
	 bWriter.flush();
	 bWriter.close();
	 
}
}
